/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package za.ac.cput.DesignPatterns.Creational.prototype;

/**
 *
 * @author Nashief
 */
public class Dog implements Prototype {
String sound;

    public String getSound() {
        return sound;
    }

    public void setSound(String sound) {
        this.sound = sound;
    }

    public Dog() {
    }


public Dog(String sound){
this.sound=sound;
}

    @Override
    public Prototype doClone() {
        return new Dog(sound);
    }
    public String toString(){
    return "This dog says "+sound;
    }
    
}
